package cz.muni.fi.pa165.dundd.soap.server;

import javax.xml.ws.Endpoint;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Server {

    public static void main(String[] args) throws InterruptedException {
        String address = "http://localhost:9000/DundD/soap";
       
        Endpoint.publish(address + "/administrator", new ClassPathXmlApplicationContext("applicationContext-SOAP.xml").getBean("administratorSOAP"));
        Endpoint.publish(address + "/troop", new ClassPathXmlApplicationContext("applicationContext-SOAP.xml").getBean("troopSOAP"));
        System.out.println("Server is running...");
    }
}
